<ion-header>
    <ion-navbar>
        <ion-title>
            实例-通讯录
        </ion-title>
    </ion-navbar>
</ion-header>

<ion-content>
        <button *ngIf="formatContacts.length==0"  ion-button block (click)="getContact()">获取通讯录</button>
        <ion-list>
            <ion-item *ngFor="let item of formatContacts">
                <img class="img" src="assets/images/head.png">
                <h2 class="name" >{{item.displayName}}</h2>
                <h2 class="phone" >{{item.phoneNumber}}</h2>
            </ion-item>
        </ion-list>
</ion-content>